package com.haizhi.crm.biz.service;

import com.haizhi.crm.biz.constant.AccountType;
import com.haizhi.crm.biz.constant.CompanyBasicType;
import com.haizhi.crm.biz.model.*;
import com.haizhi.crm.common.model.Response;

import java.util.List;

/**
 * Created by haizhi on 2018/3/6.
 */
public interface CompanyService {


    Object getRelationship(RelationshipQo relationshipQo) throws Exception;

    Response findProductSigns(CompanyProductSignQo companyStartServiceQo);


    Object getBasic(String id, CompanyBasicType companyBasicType) throws Exception;

    /**
     * 查询公司
     *
     * @param companyKeys 逗号分割的company Key
     * @return
     */
    List<CompanyVo> queryCompanysByKeys(String companyKeys);

    /**
     * 查询公司
     *
     * @param companyKey
     * @return
     */
    CompanyVo queryCompanyByKey(String companyKey);

    /**
     * ES中查询客户信息
     *
     * @param customerKey
     * @return
     */
    CompanyVo queryByCustomerKey(String customerKey);

    /**
     * ES中查询客户信息
     *
     * @param customerName
     * @return
     */
    Response findByName(String customerName);

    /**
     * 查询company集合
     *
     * @param employeeNos 客户经理employeeNo集合
     * @return
     */
    List<CompanyVo> queryCompanysByCustomerManagers(List<String> employeeNos);


    /**
     * 到es搜索客户列表
     *
     * @return
     */
    Response searchCustomers(SearchCustomerReqQo searchCustomerReqQo);

    Response advancedSearch(CompanyAdvancedSearchQo companyAdvancedSearchQo);

    Object getAccount(String companyKey, AccountType accountType);

    Object getTransfer(String accountNo);

}
